package c15.s17.ls2.reflect;

import java.util.ArrayList;

public class FilledList<T> extends ArrayList<T>{
	/**
	 * 
	 */
	private static final long serialVersionUID = 1L;

	public FilledList(Class<? extends T> type, int size){
		try{
			for(int i  = 0; i < size; i++){
				add(type.newInstance());
			}
		}catch(Exception e){
			throw new RuntimeException(e);
		}
	}
}
